import request from '@/utils/request'

export function login(data) {
  return request({
    url: '/sys/login',
    method: 'post',
    data
  })
}

export function getInfo() {
  return request({
    url: '/sys/role/list/enabled',
    method: 'get'

  })
}

// 获取-用户基本资料
export const getUserInfo = () => {
  return request.get('/sys/profile')
}

// 修改密码接口
export const changePass = (data) => {
  return request({
    url: '/sys/user/updatePass',
    method: 'PUT',
    data
  })
}
